package com.shxt.model;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import com.shxt.pojo.D_File_Root_Struct;
import com.shxt.service.D_File_Root_StructService;

public class CreateNetdisk {
	public CreateNetdisk() {

	}

	public List<D_File_Root_Struct> createFolder(long userID) {
		List<D_File_Root_Struct> dfrs = D_File_Root_StructService.getInstance()
				.selectUserFolder(userID);
		return dfrs;
	}
	
	public List<D_File_Root_Struct> createRootFolder(long userid,long folderid){
		Map<String,String> mss = new HashMap<String,String>();
		mss.put("File_Owner",userid+"");
		mss.put("Folder_Father_Id",folderid+"");
		List<D_File_Root_Struct> dfrs = D_File_Root_StructService.getInstance()
				.selectFolder(mss);
		return dfrs;
	}
	public List<D_File_Root_Struct> backRootFolder(long userid,long folderid){
		Map<String,String> mss = new HashMap<String,String>();
		mss.put("File_Owner",userid+"");
		mss.put("Folder_Id",folderid+"");
		System.out.println(mss);
		List<D_File_Root_Struct> dfrs = D_File_Root_StructService.getInstance()
				.selectFolderByFolderId(mss);
		return dfrs;
	} 
}
